package com.example.myfr.framgment;

import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;

import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.fragment.app.Fragment;

import com.example.myfr.R;

public class FirstFragment extends Fragment {
    private static String ARG_PARAM1="paran1";
    private static String ARG_PARAM2="paran2";
    private static FirstFragment mFragment;
    String mParams1;
    public static FirstFragment newInstance(String paran1,String paran2){
        mFragment =new FirstFragment();
        Bundle arg=new Bundle();
        arg.putString(ARG_PARAM1,paran1);
        arg.putString(ARG_PARAM2,paran2);
        mFragment.setArguments(arg);
        return mFragment;
    }

    @Override
    public void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        if (getArguments()!=null){
        mParams1=getArguments().getString(ARG_PARAM1);
        }
    }

    @Nullable
    @Override
    public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
       return inflater.inflate(R.layout.fragment,container,false);

    }
}
